package me.ywd.provider.controller;

import lombok.extern.slf4j.Slf4j;
import me.ywd.provider.config.CountCache;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author Ye_Wenda
 * @Date 8/31/2017
 */
@Slf4j
@RestController
public class ProviderController {
    @GetMapping("/demo")
    public String demo() {
        CountCache.count++;
        log.warn("Provider has just been invoked " + CountCache.count + " times");
        return "provider";
    }
}
